package com.ktgj.service.service.impl;

import java.util.List;
import com.ktgj.common.core.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ktgj.service.mapper.AdditionalservicesMapper;
import com.ktgj.service.domain.Additionalservices;
import com.ktgj.service.service.IAdditionalservicesService;

/**
 * 值机附加服务
Service业务层处理
 * 
 * @author ruoyi
 * @date 2021-09-03
 */
@Service
public class AdditionalservicesServiceImpl implements IAdditionalservicesService 
{
    @Autowired
    private AdditionalservicesMapper additionalservicesMapper;

    /**
     * 查询值机附加服务

     * 
     * @param additionalServicesId 值机附加服务
ID
     * @return 值机附加服务

     */
    @Override
    public Additionalservices selectAdditionalservicesById(Long additionalServicesId)
    {
        return additionalservicesMapper.selectAdditionalservicesById(additionalServicesId);
    }

    /**
     * 查询值机附加服务
列表
     * 
     * @param additionalservices 值机附加服务

     * @return 值机附加服务

     */
    @Override
    public List<Additionalservices> selectAdditionalservicesList(Additionalservices additionalservices)
    {
        return additionalservicesMapper.selectAdditionalservicesList(additionalservices);
    }

    /**
     * 新增值机附加服务

     * 
     * @param additionalservices 值机附加服务

     * @return 结果
     */
    @Override
    public int insertAdditionalservices(Additionalservices additionalservices)
    {
        additionalservices.setCreateTime(DateUtils.getNowDate());
        return additionalservicesMapper.insertAdditionalservices(additionalservices);
    }

    /**
     * 修改值机附加服务

     * 
     * @param additionalservices 值机附加服务

     * @return 结果
     */
    @Override
    public int updateAdditionalservices(Additionalservices additionalservices)
    {
        additionalservices.setUpdateTime(DateUtils.getNowDate());
        return additionalservicesMapper.updateAdditionalservices(additionalservices);
    }

    /**
     * 批量删除值机附加服务

     * 
     * @param additionalServicesIds 需要删除的值机附加服务
ID
     * @return 结果
     */
    @Override
    public int deleteAdditionalservicesByIds(Long[] additionalServicesIds)
    {
        return additionalservicesMapper.deleteAdditionalservicesByIds(additionalServicesIds);
    }

    /**
     * 删除值机附加服务
信息
     * 
     * @param additionalServicesId 值机附加服务
ID
     * @return 结果
     */
    @Override
    public int deleteAdditionalservicesById(Long additionalServicesId)
    {
        return additionalservicesMapper.deleteAdditionalservicesById(additionalServicesId);
    }
}
